import { dealOpts, USER, FIRM } from './../api_type'
import request from '@/util/request'

const userGetInfo = (params, opts) => {
  return request.get(dealOpts(USER + '/getInfo', opts), params)
}

const userUpdatePwd = (params, opts) => {
  return request.get(dealOpts(USER + '/modifyPasswd', opts), params)
}

const adminLogin = (params, opts) => {
  return request.get(dealOpts(FIRM + '/staffLogin', opts), params)
}

const adminLogout = (params, opts) => {
  return request.get(dealOpts(USER + '/logout'), params)
}

export default {
  userGetInfo,
  userUpdatePwd,
  adminLogin,
  adminLogout
}
